import http from "@/utils/request"
declare global {
    interface ProductParam{
        product_id?:string;
        category_id?:string
    }
}
export let ProductApi=(params:ProductParam)=>http.get("/product/get_product",{
    params
})
export const getCategory = () => http.get('/category/getCategory')

//删除类目

export let deleteCategory = (category_id:any) => http.get('/category/delCategory', {
    params: {
        category_id,
    }
})
//上传类目图片

export const uploadCategoryImg = () => http.post('/students/uploadStuAvatar')

// 添加项目
export const addCategory = (categoryName:any, categoryImgurl:any) => http.post('/category/addCategory', {
    categoryName,
    categoryImgurl
})